<template>
    <header>
        <!-- <svg class="icon" aria-hidden="true">
            <use xlink:href="#icon-zuo"></use>
        </svg> -->
        <span>{{titleSpring}}</span>
    </header>
</template>
<script>
import titleJs from "@/router/title.js"

export default {
    name: 'appHeader',
    data:function(){
        return {
            titleSpring:"业绩统计"
        }
    },
    created() {
        titleJs.$on('titleSpring', target => {
                this.titleSpring = target;
                console.log(this.titleSpring)
        });
    }
}

</script>
<style>
header {
    height: 1.17rem;
    background: #333a4b;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center
}



 /* header .icon {
    margin-left: 0.43rem
}  */

header>span {
    font-size: 0.36rem;
    display: flex;
    flex: 1;
    /* margin-left: calc(-0.43rem - 36px); */
    justify-content: center
}
</style>